<ui:composition template="/WEB-INF/templates/defaultLayout.xhtml" 
				xmlns="http://www.w3.org/1999/xhtml"
				xmlns:h="http://java.sun.com/jsf/html"
	  			xmlns:p="http://primefaces.org/ui" 
      			xmlns:ui="http://java.sun.com/jsf/facelets"
      			xmlns:c="http://java.sun.com/jsp/jstl/core"
	  			xmlns:f="http://java.sun.com/jsf/core">
	<ui:define name="title">
		#{lang.getTrans("ui.mobile.service.situation.title")} 
	</ui:define>
	
	<ui:define name="layoutCenter">
		<h:form>
		<p:growl id="growl" showDetail="true" />
			<p:breadCrumb>
				<p:menuitem value="#{lang.getTrans('ui.mobile.common.bread.home')}" url="/home.xhtml"/>
				<p:menuitem value="#{lang.getTrans('ui.mobile.common.bread.service.situation')}" url="/crud/serviceSituation/serviceSituationList.xhtml"/>
			</p:breadCrumb>
			<p:dataTable id="basic" var="serviceSituation" value="#{serviceSituationBean.serviceSituations}" paginator="true" rows="15" 
				paginatorTemplate="{CurrentPageReport} {FirstPageLink} {PreviousPageLink} {PageLinks} {NextPageLink} {LastPageLink} {RowsPerPageDropdown}" >
				
				<p:column id="idServiceButton" style="width:14px; text-align:center;" sortBy="#{serviceSituation.idServiceSituation}">
					<f:facet name="header">	
						<p:commandButton style="width:18px;height:18px;" title="#{lang.getTrans('ui.mobile.common.new')}" 
						icon="ui-icon-circle-plus" action="#{serviceSituationBean.toForm}"/>				
					</f:facet>
					<p:commandButton style="width:18px;height:18px;" title="#{lang.getTrans('ui.mobile.common.delete')}" 
						icon="ui-icon-trash" action="#{serviceSituationBean.remover}" update="@form">  
   						<f:setPropertyActionListener target="#{serviceSituationBean.serviceSituation}" value="#{serviceSituation}" />
					</p:commandButton>  
				</p:column>
				
				<p:column style="width:14px;">
					<p:commandButton style="width:18px;height:18px;" title="#{lang.getTrans('ui.mobile.common.edit')}" 
						icon="ui-icon-circle-triangle-e" action="#{serviceSituationBean.toForm}">  
   						<f:setPropertyActionListener target="#{serviceSituationBean.serviceSituation}" value="#{serviceSituation}" />  
					</p:commandButton>  							
				</p:column>
				
				<p:column style="width:16px;" >
					<div style="background-color:#{serviceSituation.dsPathIcon};width:16px;height:16px;"/>
				</p:column>
				<p:column id="cdServiceSituation">
					<f:facet name="header">#{lang.getTrans('ui.mobile.service.situation.name')}</f:facet>
					<h:outputText value="#{serviceSituation.cdServiceSituation}"/>	
				</p:column>
			</p:dataTable>
		</h:form>
	</ui:define>
</ui:composition> 